﻿Imports Aras.IOM
Imports System.Xml


Partial Class GetDocuments
    Inherits System.Web.UI.Page

    Dim Dossier_id As String = ""



    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load


    End Sub


   
    Public Function NotifyAddingDocument(ByVal fileID As String, ByVal NotificationType As String) As String
        Dim result As String = "False"

        Dim conn As ConnecteurAras = New ConnecteurAras(Session("LOGON_NAME"), Session("LOGON_PASS"))
        Dim projectname As String = Session("Project")
        Dim projectid As String = conn.getProjectId(projectname)

        'send notification
        conn.NotifyforNewFile(fileID, NotificationType, projectid)


        If NotificationType = "true" Then
            'add the file to the project & delete managed_by_id
            conn.addfileToProject(fileID, projectid)

        End If




        Return result
    End Function
End Class
